package org.obs.action;

import org.obs.service.LoginService;
import org.springframework.webflow.action.FormAction;
import org.springframework.webflow.execution.Event;
import org.springframework.webflow.execution.RequestContext;

public class LogoutAction extends FormAction {

	private LoginService loginService;
	
	public LoginService getLoginService() {
		return loginService;
	}

	public void setLoginService(LoginService loginService) {
		this.loginService = loginService;
	}

	public Event logout(RequestContext context) throws Exception {
		loginService.logout();
		return success();
	}
}
